package cn.wen233.core.mapper;

import cn.wen233.basic.model.Instance;
import cn.wen233.basic.model.Service;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * Instance mapper
 *
 * @author wenei
 * @date 2021-10-24 15:05
 */
public interface InstanceMapper {

    Instance selectInstanceById(String id);

    List<Instance> selectAllInstanceByServiceId(String serviceId);

    Integer selectInstanceCountByServiceId(String serviceId);

    void insertInstance(Instance instance);

//    void updateInstance(Instance instance);

    void deleteInstance(String id);

    void batchDeleteInstance(@Param("ids") List<String> ids);

    void batchUpdateInstanceStatus(@Param("ids") List<String>ids, @Param("status") Integer status);
}
